//
//  BaseView.m
//  XiangCaoJiaYuan
//
//  Created by tongj on 2017/8/25.
//  Copyright © 2017年 tongj. All rights reserved.
//

#import "BaseView.h"

@implementation BaseView

/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/
-(void)setBorderWidth:(CGFloat)borderWidth
{
    if (borderWidth<0) {
        return;
    }
    self.layer.borderWidth = borderWidth;
}

-(void)setBorderColor:(UIColor *)borderColor
{
    self.layer.borderColor = borderColor.CGColor;
}

-(void)setCornerRadius:(CGFloat)cornerRadius
{
    if (cornerRadius<0) {
        return;
    }
    self.layer.cornerRadius = cornerRadius;
    self.layer.masksToBounds = cornerRadius>0;
}
@end
